/*--------begin change by wangwei----------*/
#include <typedefs.h>

void InitResource (pRESOURCE Resource)
{
  pthread_mutex_init(Resource, NULL);
}
void LockResource(pRESOURCE mut)
{
  pthread_mutex_lock(mut);
}

void ReleaseResource(pRESOURCE mut)
{
  pthread_mutex_unlock(mut);
}

BIT8 IsrLockResource (pRESOURCE Resource)
{
  if(pthread_mutex_trylock(Resource))
  {return FALSE;}
  else
  {return TRUE;}
}







/*--------end change----------------------*/
